Bug 536765 – GtkComboBox should set COMBO type hint for its menu
authorMatthias Clasen <matthiasc@src.gnome.org>
Wed, 11 Jun 2008 03:36:32 +0000 (03:36 +0000)
committerMatthias Clasen <matthiasc@src.gnome.org>
Wed, 11 Jun 2008 03:36:32 +0000 (03:36 +0000)
        * gtk/gtkoptionmenu.c:
        * gtk/gtkcombobox.c: Set the window type hint on popups.
        Patch by Danny Baumann

svn path=/trunk/; revision=20351

ChangeLog
gtk/gtkcombobox.c
gtk/gtkoptionmenu.c

index 9e7cf10e1014f346466e5584422e14b3a7a6cd35..bb1101348d7c82bf658f750d468ddd12bcf1da81 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,4 +1,12 @@
-2008-06-10  Christian Persch  <chpe@gnome.org>
+2008-06-10  Matthias Clasen <mclasen@redhat.com>
+
+       Bug 536765 – GtkComboBox should set COMBO type hint for its menu
+
+       * gtk/gtkoptionmenu.c:
+       * gtk/gtkcombobox.c: Set the window type hint on popups.
+       Patch by Danny Baumann
+
+2008-06-10  Matthias Clasen <mclasen@redhat.com>
 
        * gtk/gtkfilesystem.c (get_icon_for_special_directory):
        (gtk_file_system_volume_render_icon): Add standard icon names,
index 3db35f2431392d4e3aa87a017d261f986fcdd51c..8d5c12e15290f9572011be6af5bbe4bce0f2c524 100644 (file)
@@ -1575,6 +1575,9 @@ gtk_combo_box_menu_position (GtkMenu  *menu,
 
       gtk_combo_box_menu_position_over (menu, x, y, push_in, user_data);
     }
+
+  gtk_window_set_type_hint (GTK_MENU (priv->popup_widget)->toplevel,
+                           GDK_WINDOW_TYPE_HINT_COMBO);
 }
 
 static void
index 272017bf61556aaeb3df774efa9d54eebd1aa60c..d36816c265f0edebe86706bab854e6789f1342e1 100644 (file)
@@ -894,6 +894,10 @@ gtk_option_menu_position (GtkMenu  *menu,
   active = gtk_menu_get_active (GTK_MENU (option_menu->menu));
   gdk_window_get_origin (widget->window, &menu_xpos, &menu_ypos);
 
+  /* set combo box type hint for menu popup */
+  gtk_window_set_type_hint (GTK_MENU (option_menu->menu)->toplevel,
+                           GDK_WINDOW_TYPE_HINT_COMBO);
+
   menu_xpos += widget->allocation.x;
   menu_ypos += widget->allocation.y + widget->allocation.height / 2 - 2;